package com.eportal.util;

import java.io.IOException;
import java.io.InputStream;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import java.util.Properties;

import org.apache.log4j.Logger;


public class HomePageConfig {

	

//	public static Map<String, String> accessTokenMap = new HashMap<String, String>(); 
	
	public static String PMSREPORTS;
	public static String TAGENTREPORTS;
	public static String TCOMUREPORTS;
	public static String ZHANGHUGL;
	
	public static String SHENGHUOFW;
	public static String GUANGGAOGL;
	public static String GONGGAOTZ;
	public static String QUANXIANGL;
	
	public static String SHEQUGL;
	public static String ZHINENGMJ;
	public static String ZHINENGSUO;
	public static String JIFENGZ;
	public static String YINGYONGGL;
	public static String HEZUOFANGXX;
	public static String SHEQUXX;
	public static String YONGHUGL;
	public static String WUYEJIAOFEI;
	public static String SHUIFEI;
	public static String TINGCHEFEI;
	public static String BAOXIU;
	public static String ZHIFUBAO;
	
	public static String FUNC_APPLY;
	public static String FUNC_AUTH;
	
	public static String USER_WALLET;
	
	private static Logger log = Logger.getLogger(HomePageConfig.class);
	static {
		try {
			loadConfig();
		} catch (Exception e) {
			log.error("error",e);
			throw new RuntimeException("load weixin config error " + e.getMessage());
		}
	}
	
	
	private static void loadConfig() throws IOException{
		InputStream in = Config.class.getClassLoader()
				.getResourceAsStream("homePage.properties");
		Properties props = new Properties();
		props.load(in);
		PMSREPORTS = props.getProperty("PMSREPORTS", null);
		TAGENTREPORTS = props.getProperty("TAGENTREPORTS", null);
		TCOMUREPORTS = props.getProperty("TCOMUREPORTS", null);
		ZHANGHUGL = props.getProperty("ZHANGHUGL", null);
		SHENGHUOFW = props.getProperty("SHENGHUOFW", null);
		GUANGGAOGL = props.getProperty("GUANGGAOGL", null);
		GONGGAOTZ = props.getProperty("GONGGAOTZ", null);
		QUANXIANGL = props.getProperty("QUANXIANGL", null);
		
		SHEQUGL = props.getProperty("SHEQUGL", null);
		ZHINENGMJ = props.getProperty("ZHINENGMJ", null);
		ZHINENGSUO = props.getProperty("ZHINENGSUO", null);
		JIFENGZ = props.getProperty("JIFENGZ", null);
		YINGYONGGL = props.getProperty("YINGYONGGL", null);
		HEZUOFANGXX = props.getProperty("HEZUOFANGXX", null);
		SHEQUXX = props.getProperty("SHEQUXX", null);
		YONGHUGL = props.getProperty("YONGHUGL", null);
		WUYEJIAOFEI = props.getProperty("WUYEJIAOFEI", null);
		SHUIFEI = props.getProperty("SHUIFEI", null);
		TINGCHEFEI = props.getProperty("TINGCHEFEI", null);
		BAOXIU = props.getProperty("BAOXIU", null);
		ZHIFUBAO = props.getProperty("ZHIFUBAO", null);
		FUNC_APPLY = props.getProperty("FUNC_APPLY", null);
		FUNC_AUTH = props.getProperty("FUNC_AUTH", null);
		USER_WALLET = props.getProperty("USER_WALLET", null);
	}
	
	
	public static void refreshConfig(){
		try {
			loadConfig();
		} catch (IOException e) {
			log.error("error",e);
			throw new RuntimeException("load HomePageConfig config error " + e.getMessage());
		}
	}
	


}
